<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="<?=gurl('css');?>/admin.css" />
<script language="javascript" src="<?=gurl('js');?>/jq.js"></script>
<script language="javascript" src="<?=gurl('js');?>/common.js"></script>
</head>
<body>
	<h3 style="background:#E5ECF3; padding:5px; font-size:12px;">> <a href="<?=site_url(rnadminpath().'/main/show/main');?>">首页</a> > <a href="#">小站列表</a></h3>
	<div>
	<form method="GET" action="<?=gurl(rnadminpath().'/site/index/?');?>/">
		<input type="text" name="keyword" id="keyword" class="searchWord" value="<?=$keyword;?>" dataType="Require" msg="请输入关键字" />
		<input type="submit" value="搜索" class="searchIco" />
		<input type="hidden" name="dosubmit" id="dosubmit" value="1">
		&nbsp;
		小站数量统计：<strong><?=$total_rows;?></strong>
	</form>
	</div>
	<? 
		if($desc == 'desc') {
			$showdesc = "asc";
		} else {
			$showdesc = "desc";
		}
	?>
	<div style="margin-top:10px;padding:5px;border:1px solid #9FACB7;">
		<ul class="listmenu">
			<li style="width:60px;">选择</li>
			<li style="width:60px;">LOGO</li>
			<li style="width:80px;">名称</li>
			<li style="width:60px;">域名</li>
			<li style="width:60px;">站长</li>
			<li style="width:40px;"><a href="<?=gurl(rnadminpath()."/site/index/?keyword=".$keyword."&sortby=fans&desc=".$showdesc."&dosubmit=1");?>"><? if($sortby != '0' && $sortby == 'fans'):?><font color="orange">粉丝</font><? else:?>粉丝<? endif;?></a><? if($sortby == 'fans'):?><? if($desc == 'desc'):?><img src="<?=gurl('images/down.gif');?>"><? elseif($desc == 'asc'):?><img src="<?=gurl('images/up.gif');?>"><? endif;?><? endif;?></li>
			<li style="width:40px;"><a href="<?=gurl(rnadminpath()."/site/index/?keyword=".$keyword."&sortby=visits&desc=".$showdesc."&dosubmit=1");?>"><? if($sortby != '0' && $sortby == 'visits'):?><font color="orange">访问</font><? else:?>访问<? endif;?></a><? if($sortby == 'visits'):?><? if($desc == 'desc'):?><img src="<?=gurl('images/down.gif');?>"><? elseif($desc == 'asc'):?><img src="<?=gurl('images/up.gif');?>"><? endif;?><? endif;?></li>
			<li style="width:60px;"><a href="<?=gurl(rnadminpath()."/site/index/?keyword=".$keyword."&sortby=regtime&desc=".$showdesc."&dosubmit=1");?>"><? if($sortby != '0' && $sortby == 'regtime'):?><font color="orange">申请时间</font><? else:?>申请时间<? endif;?></a><? if($sortby == 'regtime'):?><? if($desc == 'desc'):?><img src="<?=gurl('images/down.gif');?>"><? elseif($desc == 'asc'):?><img src="<?=gurl('images/up.gif');?>"><? endif;?><? endif;?></li>
			<li style="width:60px;"><a href="<?=gurl(rnadminpath()."/site/index/?keyword=".$keyword."&sortby=status&desc=".$showdesc."&dosubmit=1");?>"><? if($sortby != '0' && $sortby == 'status'):?><font color="orange">状态</font><? else:?>状态<? endif;?></a><? if($sortby == 'status'):?><? if($desc == 'desc'):?><img src="<?=gurl('images/down.gif');?>"><? elseif($desc == 'asc'):?><img src="<?=gurl('images/up.gif');?>"><? endif;?><? endif;?></li>
			<li class="lastitem" style="width:100px;">操作</li>
		</ul>
		<div class="clear"></div>
		<? if(is_array($items) && count($items)>0):?>
		<? foreach ($items as $item):?>
		<ul class="listitem">
			<li style="width:60px;"><input type="checkbox" name="id[]" id="id[]" value="<?=$item['id'];?>"></li>
			<li style="width:60px;"><img src="<?=gurl('data');?>/upload_pic/<?=$item['logo'];?>" onerror="this.onerror='';this.src='<?=gurl('images');?>/hotweblog.gif';" width="40" height="40" /></li>
			<li style="width:80px;"><? if(isset($item['title'])):?><?=$item['title'];?><? else:?><?=$item['name'];?><? endif;?><br><? if($item['certification']):?><font color="Green">认证</font><? endif;?> <? if($item['bestrecommend']):?><font color="red">每日</font><? endif;?> <? if($item['recommend']):?><font color="red">精彩</font><? endif;?> <? if($item['kankan']):?><font color="red">看</font><? endif;?> <br><? if($item['staticgirl']):?><font color="blue">主题</font><? endif;?> <? if($item['staticboy']):?><font color="blue">热闹</font><? endif;?> </li>
			<li style="width:60px;"><?=$item["domain"];?></li>
			<li style="width:60px;"><?=$item["username"];?></li>
			<li style="width:40px;"><?=$item["fans"];?></li>
			<li style="width:40px;"><?=$item["visits"];?></li>
			<li style="width:60px;"><?=date("Y-m-d H:i",$item['regtime']);?></li>
			<li style="width:60px;"><? if($item['status'] == 1):?><font color="Green">已审核</font><? else:?><font color="Red">未审核</font><? endif;?></li>
			<li class="lastitem" style="width:100px;">
				<a href="<?=gurl(rnadminpath().'/site/show/'.$item['id']);?>">查看</a>
				<a href="<?=gurl(rnadminpath().'/site/fans/'.$item['id']);?>">粉丝</a>
				<a href="<?=site_url(rnadminpath().'/site/delete/'.$item['id']);?>"  onclick="return confirm('确认删除吗');">删除</a>
			</li>
		</ul>
		<div class="clear"></div>
		<? endforeach;?>
		<? endif;?>
	</div>
	<div style="padding:5px;margin-top:10px;text-align:left;">
		<input type="button" onClick="checkall();" value="全选">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/statusselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="审核">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/unstatusselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="取消审核">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/bestrecommendselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="每日一站">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/unbestrecommendselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="取消每日">
		<input type="button" onClick="delselected('<?=gurl(rnadminpath().'/site/delselected');?>');" value="删除">
	</div>
	<div style="padding:5px;margin-top:10px;text-align:left;">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/certselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="认证">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/uncertselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="取消认证">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/recommendselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="精彩">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/unrecommendselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="取消精彩">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/kankanselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="看看">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/unkankanselected/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="取消看看">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/recommendselectedstatic/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page.'&type=2');?>');" value="主题">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/recommendselectedstatic/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page.'&type=1');?>');" value="热闹">
		<input type="button" onClick="goselected('<?=gurl(rnadminpath().'/site/unrecommendselectedstatic/?keyword='.$keyword.'&sortby='.$sortby.'&desc='.$desc.'&dosubmit=1&page='.$page);?>');" value="取消主题热闹">
	</div>
	<div class="pagestring">
		<?=$pagestring;?>
	</div>
</body>
</html>
